version 16.1
clear all
cd "MYPATH\derived\make_analysis_sample"
adopath + ../../ado/
pause on

cap log close

log using "additional_sample_stats.log", replace

preliminaries
foreach PATH in RESULTS TRANSFER TEMP {
	if "`PATH'" != "TEMP" cap mkdir "${`PATH'}\derived\make_analysis_sample"
    if "`PATH'" != "TEMP" cap mkdir "${`PATH'}\derived\make_analysis_sample\figures"
	if "`PATH'" == "TEMP" cap mkdir "${`PATH'}\derived\make_analysis_sample"
}

graph set window fontface default
graph set ps fontface default
graph set window fontfacemono "Consolas"
graph set ps fontfacemono "Consolas"

program main
	use "${DATA}\analysis_sample", clear
	
	di "From full sample"
	*find share of analysis sample with different maternal age calc methods
	count
	tab age_flag, mi
	tab date_preg_flag, mi
	*tab impute_birth_month_discrep, mi
	
	use "${DATA}/model_sample", clear
	
	di "From model sample"
	*find share of analysis sample with different maternal age calc methods
	count
	tab age_flag, mi
	tab date_preg_flag, mi
	tab married due_dt_year_married, mi
	tab educ due_dt_year_educ, mi
	tab impute_birth_month_discrep, mi
end

*EXECUTE
main
